|
![]() | |||
![]() |
|||
![]() | |||
|
![]() |
![]() | |||||||||||||||
Working with direct to stage digital video in Director
Each digital video sprite has a property called 'directToStage'. This property allows QuickTime or AVI drivers installed on the computer to completely control the video playback. When 'directToStage' is disabled, Director composites the video in an off-screen buffer before displaying it on the stage. For more information about DTS see Working with direct to stage (TechNote 16770). When
'directToStage' is enabled digital video sprites display on top of all
other sprites on the stage regardless of the channel the sprite is in. Ink
effects are not available for video sprites when "directToStage" is
enabled. 'DirectToStage' usually yields smooth digital video playback and
is enabled by default so the digital video sprite will play at or near its
full frame rate. This property can be enabled or disabled via Lingo (see
script below) or the AVI/QuickTime tab in the Property
Inspector. member("myVideo").directToStage = True When "Play every frame" is enabled, Director will attempt to play every visual frame of the digital video. Whether or not this results in a performance improvement is subjective: if dropped frames are a problem, then "Play every frame" will usually prevent dropped frames. However, depending on the data rate of the digital video, the digital video sprite may not play any more smoothly than before. In addition, playing every frame may cause the digital video to take more time to play. Cleaning up
artifacts The
stageColor set the stageColor = the stageColor Transitions Animation Clean up
behavior Instead of using the Lingo "set the stageColor = the stageColor", the following technique sets the "visible" property of the digital video sprit. The following technique holds the playback head on the frame until the digital video finishes playing, and then cleans up the artifacts. The behavior will automatically determine the sprite channel number and other sprite and member properties, so you shouldn't need to change the Lingo in this script for it to work. Assign this behavior directly to the digital video sprite. -------------------------------------------------------- -- Play digital video, clean up & then continue. property myDVSpriteNum, myDVLength on beginSprite me -- Initialization: myDVSpriteNum = me.spriteNum myDVMember = sprite(myDVSpriteNum).member sprite(myDVSpriteNum).visible = TRUE myDVLength =member(myDVMember).duration end on exitFrame me -- Hold on current frame & play --digital video until end: case (TRUE) of (sprite(myDVSpriteNum).movieTime < myDVLength): go to the frame otherwise go to the frame + 1 end case end on endSprite me -- Clean up direct to stage digital video sprite: sprite(myDVSpriteNum).visible = FALSE sprite(myDVSpriteNum).visible = TRUE end ------------------------------------------------------- Additional
information:
|
![]() |
![]() |
Use of this website signifies your agreement to the Terms of Use. Privacy | Site Map | Contact us | Accessibility | Report Piracy |